<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<style>
    div{
        width: 400px;
        height: 100px;
        border: 1px solid blueviolet;
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%,-50%);
        line-height: 100px;
        text-align: center;
    }
</style>
<script>
    window.onload = function(){
        document.getElementById("span1").innerText = "0%";
        document.getElementById("progress1").value = 0;

        let jd = document.getElementById("progress1").value;
        let timer = null;

        document.getElementById("start").onclick = function(){
            document.getElementById("start").disabled = true;
            timer = setInterval(function(){
                jd++;
                if(jd>100){
                    clearInterval(timer);
                }else{
                    document.getElementById("span1").innerText = jd + "%";
                    document.getElementById("progress1").value = jd;
                }
            },100)
        }
        document.getElementById("stop").onclick = function(){
            clearInterval(timer);
            document.getElementById("start").disabled = false;
        }
    }
</script>
<body>
    <button id="start">开始</button>
    <button id="stop">暂停</button>
    <div>
        <span>当前进度<span id="span1">10%</span></span>
        <progress max="100" min="0" value="10" id="progress1"></progress>
    </div>
</body>
</html>